package org.yak.core.store;

import java.io.Serializable;

public class PageParam  implements Serializable {

	private static final long serialVersionUID = 6739075362261232248L;

	private int offset = 0;
	private int limit = 10;

	private int pageIndex=0;

	/**
	 * 是否分页true,false
	 */
	private boolean paging;

	public PageParam() {
		this.offset = 0;
		this.limit = 10;
	}

	public PageParam(int offset, int limit) {
		this.offset = offset;
		this.limit = limit;
	}

	public int getOffset() {
		return offset;
	}

	public int getLimit() {
		return limit;
	}

	public void setOffset(int offset) {
		this.offset = offset;
	}

	public void setLimit(int limit) {
		this.limit = limit;
	}

	public int getPageIndex() {
		return pageIndex;
	}

	public void setPageIndex(int pageIndex) {
		this.pageIndex = pageIndex;
		this.offset = pageIndex;
	}

	public boolean isPaging() {
		return paging;
	}

	public void setPaging(boolean paging) {
		this.paging = paging;
	}

}
